package com.ice_hufs.medical_in_myhand;

import android.app.Activity;
import android.content.Intent;
import android.net.Uri;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.Window;
import android.view.WindowManager;
import android.widget.Button;

public class MainActivity extends Activity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        requestWindowFeature(Window.FEATURE_NO_TITLE);
        getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN
                , WindowManager.LayoutParams.FLAG_FULLSCREEN);

        setContentView(R.layout.activity_main);

        Button hospital_btn = (Button)findViewById(R.id.hospital_btn);
        hospital_btn.setOnClickListener(new OnClickListener(){
            public void onClick(View v){
                Intent my_Intent= new Intent(MainActivity.this, hospital_list.class);
                startActivity(my_Intent);

            }
        });

        Button hotel_flight_btn = (Button)findViewById(R.id.hotel_flight_btn);
        hotel_flight_btn.setOnClickListener(new OnClickListener(){
            public void onClick(View v){
                Intent myIntent= new Intent(getApplicationContext(), hotel_hospital.class);
                startActivity(myIntent);

            }
        });

    }

    @Override
    public boolean onCreateOptionsMenu(Menu menu) {
        // Inflate the menu; this adds items to the action bar if it is present.
        getMenuInflater().inflate(R.menu.main, menu);
        return true;
    }

    @Override
    public boolean onOptionsItemSelected(MenuItem item) {
        // Handle action bar item clicks here. The action bar will
        // automatically handle clicks on the Home/Up button, so long
        // as you specify a parent activity in AndroidManifest.xml.
        int id = item.getItemId();
        if (id == R.id.action_settings) {
            return true;
        }
        return super.onOptionsItemSelected(item);
    }
}
